package edu.xlh.travel.enumeration;

import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;

public enum OrderTypeEnum {
    scenicOrder("0", "景点订单"),
    hotelOrder("1", "酒店订单"),
    ;
    private static final Set<String> enumSet = new HashSet<>(50);

    static {
        Arrays.asList(SFTPOperateTypeEnum.values()).forEach(e -> enumSet.add(e.getCode()));
    }

    public static boolean hasEnum(String code) {
        return enumSet.contains(code);
    }

    //code
    private String code;

    //描述
    private String desc;

    OrderTypeEnum(String code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public String getCode() {
        return code;
    }
    public String getDesc() {
        return desc;
    }
}
